<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
<link rel="stylesheet" href="/res/css/style.css" />
<script src="/res/js/jquery.js"></script>
<script src="/res/js/com.js"></script>
<script type="text/javascript">
//登陆
function login(){
	//登录成功后，返回登录之前的页面
	window.location.href = "/shopping/login.shtml?returnUrl=" + window.location.href;
}
//注册
function register(){
	//注册成功后，返回登录页面
	window.location.href = "/shopping/register.shtml";
}
//退出
function logout(){
	//退出成功后，返回登录之前的页面
	window.location.href= "/shopping/logout.shtml?returnUrl=" + window.location.href;
}

//我的订单
function myOrder(){
	window.location.href="/buyer/index.shtml";
}
</script>
</head>
<body>
<div class="bar"><div class="bar_w">
	<p class="l">
		<span class="l">
			收藏本网站！北京<a href="#" title="更换">[更换]</a>
		</span>
	</p>
	<ul class="r uls">
	<c:if test="${!isLogin }">
		<li class="dev"><a href="javascript:void(0)" onclick="login()"  title="登录">[登录]</a></li>
		<li class="dev"><a href="javascript:void(0)" onclick="register()" title="免费注册">[免费注册]</a></li>
	</c:if>
		<c:if test="${isLogin }">
			<li class="dev">您好：${buyer.username}，欢迎来到新巴巴运动网！</li>
			<li class="dev"><a href="javascript:void(0)" onclick="logout()" title="退出">[退出]</a></li>
		<li class="dev"><a href="javascript:void(0)" onclick="myOrder()" title="我的订单">我的订单</a></li>
	</c:if>
	<li class="dev"><a href="#" title="在线客服">在线客服</a></li>
	<li class="dev after"><a href="#" title="English">English</a></li>
	</ul>
</div></div>
</body>
</html>